package com.itheima.util;

import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import java.time.LocalDateTime;

@Component
@Slf4j
public class TaskUtil {

	@Scheduled(fixedRate = 5000)
	public void task(){
		LocalDateTime now = LocalDateTime.now();
		String str = "111";
		//log.info("当前时间: {} 字符串str{}",now,str);

		log.info("当前时间: {} ",now);
	}
}
